package it.antonio.ilpizze.db.statistics;

import it.antonio.ilpizze.db.core.StatisticRecord;

import java.util.List;

public class StatisticsResult {
	private List<StatisticRecord> records;
	
	public StatisticsResult(List<StatisticRecord> records) {
		this.records = records;
	}

	public <T> T get(StatisticMetric<T> metric){
		return metric.calculate(records);
	}
}
